package cn.bugDance.domain.activity.event;

import cn.bugDance.types.response.BaseEvent;
import org.apache.commons.lang3.RandomStringUtils;

import java.util.Date;

public class ActivitySkuStockOverEvent extends BaseEvent<Long> {

    public static String topic = "skuStockOverTopic";


    public static ActivitySkuStockOverEvent create(Long sku){
        ActivitySkuStockOverEvent event = new ActivitySkuStockOverEvent();
        event.setData(sku);
        event.setId(RandomStringUtils.randomNumeric(6));
        event.setTimestamp(new Date());

        return event;
    }


}
